package loan.calc.constant.dict;

import lombok.AllArgsConstructor;
import lombok.Getter;
import loan.calc.constant.dict.base.BaseDictEnum;
import loan.calc.constant.dict.base.DictEnum;

/**
 * 周期内利息计算，时间区段分割月天方式枚举
 *
 * @author Liusuo Dong
 * @date 2020/10/9
 */
@Getter
@AllArgsConstructor
@DictEnum(value = "PeriodSplitMode", description = "周期内利息计算，时间区段分割月天方式枚举")
public enum PeriodSplitModeDictEnum implements BaseDictEnum {

    BEFORE_MONTH_THEN_DAY("按月分割，先算整月数，后算零天数"),
    BEFORE_DAY_THEN_MONTH("按月分割，先算零天数，后算整月数"),
    ONLY_DAY("按天分割，只算天数"),
    ;

    private final String value;

    private final String description;

    PeriodSplitModeDictEnum(String description) {
        this.description = description;
        this.value = name();
    }
}
